import Taro, { Component } from '@tarojs/taro'
import { View, Text,Image, Button } from '@tarojs/components'
import { AtTabs, AtTabsPane } from 'taro-ui'
import './index.less'
import wechat from '../../img/wechat2.png'
import searchImg from '../../img/searchimg.png'

export default class share extends Component {

  config = {
    navigationBarTitleText: '',
    navigationBarBackgroundColor:'#f6bd58',
    disableScroll: true
  }


  // componentWillMount () { }

  // componentDidMount () { }

  // componentWillUnmount () { }

  // componentDidShow () { }

  // componentDidHide () { }

  render () {
    const data = {
      information:{
        head:'http://iph.href.lu/300x200?text=占位',
        nickName:'你听我说',
        img:'http://iph.href.lu/300x200?text=占位'
      }
    }
    return (
      <View className='index'>
        {/**中间大框 */}
        <View className='white-box'>
          {/**第一行头像昵称 */}
          <View className='white-top-box'>
            <Image src={data.information.head} className='head' />
            <Text className='nickName'>{data.information.nickName}</Text>
          </View>
          <View className='code-box'>
            <Image src={data.information.img} className='code' />
          </View>
        </View>
        <View className='share-bottom-box'>
          <Text className='share-bottom-text'>更多分享方式</Text>
          <Image src={wechat} className='wechat' />
          <Button open-type='share' className='share-button'>微信</Button>
        </View>
      </View>
    )
  }
}

